// views operation system abstract layer
#ifndef __VIEWS_C_LWIP_CC_H__
#define __VIEWS_C_LWIP_CC_H__

#include "std/std.h"
#include "std/debug.h"

#ifdef __cplusplus
extern "C" {
#endif

#define LWIP_NO_STDINT_H	(1)

typedef unsigned char u8_t;
typedef char s8_t;
typedef unsigned short u16_t;
typedef short s16_t;
typedef unsigned int u32_t;
typedef int s32_t;
typedef unsigned int mem_ptr_t;

// todo:
/*
PACK_STRUCT_FIELD(x)
PACK_STRUCT_STRUCT
PACK_STRUCT_BEGIN
PACK_STRUCT_END
*/

#define LWIP_PLATFORM_DIAG(x) do {dbg_output3 x;} while(0)
#define LWIP_PLATFORM_ASSERT kassert

// todo:
/*
SYS_ARCH_DECL_PROTECT(x) - declare a protection state variable.
SYS_ARCH_PROTECT(x)      - enter protection mode.
SYS_ARCH_UNPROTECT(x)    - leave protection mode.
*/

// make lwip/arch.h define the codes which are used throughout
#define LWIP_PROVIDE_ERRNO

#ifdef __cplusplus
}
#endif
#endif
/* EOF */
